package com.wwj.auction.schedule.client;

import com.wwj.auction.common.result.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * 远程服务接口
 *
 * @author wwj
 */
@FeignClient("service-login")
public interface ServiceLoginClient {

    /**
     * 查询已经结束拍卖的商品列表
     *
     * @return
     */
    @GetMapping("/login/shop/scan")
    R scanShop();

    /**
     * 查询商品最终成交的买家
     *
     * @param shopId
     * @return
     */
    @GetMapping("/login/offerRecord/find/buyer/{shopId}")
    R findSeller(@PathVariable Integer shopId);

    /**
     * 更改商品的状态
     *
     * @param shopStatus
     * @param shopId
     * @return
     */
    @GetMapping("/login/shop/status/{shopStatus}/{shopId}")
     R status(
            @PathVariable("shopStatus") Integer shopStatus,
            @PathVariable("shopId") Integer shopId);
}
